﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Drawing;
using System.Collections;
namespace papercut2.Data.Global
{
    //这个类用于存放图片处理各个过程公用的数据
    class GlobalData
    {
        //原始位图
        private static Bitmap pic;
        //灰度化的方式
        private static int choice = 0;

        //二值化的阀值
        private static int num;

        //边界提取的范围
        private static int low =200;
        private static int high = 255;

        //提取角点圆的半径
        private static int radio = 5;
        
        //园内像素点的个数
        private static int pixelNum = (int)((Math.PI*radio*radio)/2);
      
        //get,set方法
        #region
        public static Bitmap Pic
        {
             get
            {
                return pic;
            }
            set
            {
                pic = value;
            }
        }
        public static int Choice
        {
            get
            {
                return choice;
            }
            set 
            {
                choice = value;
            }
        }
        public static int Num
        {
            get
            {
                return num;
            }
            set 
            {
                num = value;
            }
        }
        public static int Low
        {
            get {
                return low;
            }
            set
            {
                low = value;
            }
        }

        public static int High
        {
            get
            {
                return high;
            }
            set
            {
                high = value;
            }
        }


        public static int R
        {
            get
            {
                return R;
            }
            set
            {
                R = value;
            }
        }

        public static int PixelNum
        {
            get
            {
                return pixelNum;
            }
            set
            {
                pixelNum = value;
            }
        }
      

        #endregion

    }
}
